package com.godme.es.bean;


import lombok.Data;
import lombok.ToString;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.DateFormat;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.sql.Date;


@Data
@ToString
@Document(indexName = "position")
public class ESPosition {

    @Id
    private Long id;

    private String companyName;

    private String positionAdvantage;

    // boolean在lombok中生成方法不是getXXX，而是isXXX，规范写法boolean不能isXXX
    private boolean forward;
    private boolean schoolJob;


    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date generateTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date bornTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date offlineTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date adviceTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date verifyTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date adStartTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date adEndTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date weightStartTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date weightEndTime;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date prolong_offline_time;
    @Field(type = FieldType.Date, format = DateFormat.basic_date)
    private Date createTime;

    private Long companyId;
    private Long salaryMin;
    private Long salaryMax;
    private Long salaryMonth;
    private Long isEnable;
    private Long isIndex;
    private Long orderby;
    private Long isAdvice;
    private Long showorder;
    private Long publishUserId;
    private Long isReward;
    private Long isExpired;
    private Long positionDetailPV;
    private Long positionDetailPV_cnbeta;
    private Long receivedResumeCount;
    private Long refuseResumeCount;
    private Long markCanInterviewCount;
    private Long haveNoticeInterCount;
    private Long isForbidden;
    private Long adWord;
    private Long adTimes;
    private Long adBeforeDetailPV;
    private Long adAfterDetailPV;
    private Long adBeforeReceivedCount;
    private Long adAfterReceivedCount;
    private Long adjustScore;

    private String positionName;
    private String salary;
    private String education;
    private String workYear;
    private String jobNature;
    private String chargeField;
    private String email;
    private String publishTime;
    private String city;
    private String workAddress;
    private String rewardMoney;
    private String comeFrom;
    private String reason;
    private String adRankAndTime;
    private String forwardEmail;
    private boolean type;
}
